package br.com.lh.urabuilder.view.properties
{
	import br.com.lh.urabuilder.domain.xml.ConditionalAction;
	import br.com.lh.urabuilder.event.SaveConditionalPropertiesEvent;
	
	import com.adobe.cairngorm.control.CairngormEvent;
	
	/**
	 * A Propertie Form that has 
	 * a internal grid in which the user can select the conditional options.
	 * 
	 * 
	 * @author Luiz Henrique
	 * 
	 */
	public class CondtionalPropertiesForm extends PropertiesForm 
	{
		private var optionGrid:OptionGrid;
		
		public function CondtionalPropertiesForm(){
			super();
		}
		
		public override function updateValues():void{
			basicForm();
			optionGrid =new OptionGrid(ConditionalAction(component.uraAction));
			form.addChild(optionGrid);
			createButtons();
			setFocus();
		}
		
		public override function okEvent():CairngormEvent{
			return new SaveConditionalPropertiesEvent(component,optionGrid.optionList);
		}
		
		
		
		
		
	}
}